home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Aminet 5
/
Aminet 5 - March 1995.iso
/
Aminet
/
util
/
misc
/
PatchGen.lha
/
PatchGen.doc
< prev
next >
Wrap
Text File
|
1994-09-18
|
5KB
|
130 lines
Patch Generator
(c) 1994 Martin Mares, MJSoft System Software
================================================================================
Preface
=======
PatchGen, PatchGenL, Patcher and their documentation are Copyright (c) Martin
Mares, MJSoft System Software, Prague, Czech Republic.
This archive can be freely redistributed, as long as all of its files are
included in their original form without any additions, deletions or
modifications, and no more than a nominal fee is charged for its distribution.
All copyright notices in the programs and accompanying documentation files must
remain on their places. Also '.displayme' and other similar files may not be
added. This is generally known as FREEWARE.
The only exception to this rule is the Patcher executable which can be spread
without any restrictions in its original unmodified form in any kind of software
package (including commercial products).
This software is provided "AS IS" without warranty of any kind, either
expressed or implied. The author is not responsible for any damage caused by
it.
Introduction
============
Many people distribute new versions of software. This task can be done in two
significantly different ways:
(1) Redistributing all files. This method is simple, the user has no need to
have the older version to install the new one. But the archives are usually
lengthy and consume much disk space.
(2) Distribution of patches. When this method is used, only the differences
between the previous version and the recent one are distributed. The updates
require much less disk space, but the user needs to have the previous version.
This turns out to be an advantage when distributing updates of commercial
software, because the new version is available only to legal users which have
the old one. Also third-party patches to commercial software can be spread this
way legally.
If you want to use the second method of distribution, you need some software
to generate and apply the patches. There are already some patch generators (for
example lpatch), but they're usually very slow, their size is not so small as it
could be if they were written better and the products itself are big. The
solution is ... PatchGen!
PatchGen eliminates at least of the previously mentioned disadvantages -- its
patch files are relatively short and the programs themself are very small and
run under any version of AmigaDOS starting with 1.2 (I think it would work also
under 1.1, but I have never seen this kickstart. If you have it, let me know!).
Requirements
============
- Kickstart 1.2 or higher.
- arp.library - it's required only by the patch generators. Patcher runs
without it.
- 68000 or higher
Generating patches
==================
There are two patch generators in this archive: PatchGen and PatchGenL.
Both of them produce the same patch file format, but they use a slightly
different algorithm. For small files, use PatchGen. For large files, PatchGenL
could produce better results and might be faster.
Usage:
PatchGen[L] <file1> <file2> <dest> [CHANGE]
<file1> - the older file
<file2> - the newer file (PatchGen will produce a patch to create <file2> from
<file1>.
<dest> - file to write the patch table to
CHANGE - in some cases, the versions are too different to get a patch table
of reasonable size, but you _want_ to make the new file dependent on the old one
(commercial software, grr!). In this case, specify the CHANGE option. The new
file will be stored in simple way, but it will be encrypted by contents of the
older file which makes it impossible to create the new file without having the
old one.
Some dots will be printed as a progress indicator.
Warning: Creation of patch tables requires a lot of memory -- a size of
<file1> plus two times size of <file2>.
Applying patches
================
To apply the patches, enter:
Patcher <file1> <file2> <patchtab>
This command transforms <file1> to <file2> using given patch table produced
by PatchGen or PatchGenL. The <file1> is checked to be the correct source file
by comparing its checksum with the one stored in the patch file.
Memory requirements: <file1> + <file2> + <patchfile>. (a lot of, grr!)
Notes
=====
This program is not the best solution if searching for differences between
two text files. In this case, it would be better to use GNU diff.
Plans:
- New version of Patcher eating less memory.
- Faster searching algorithms.
Send suggestions, bug reports and flames to <mjsoft@k332.feld.cvut.cz>.